namespace DesignPattern.Behavioral.Interpreter
{
    public class OrExpress : IExpress
    {
        private IExpress _exp1;
        private IExpress _exp2;

        public OrExpress(IExpress exp1, IExpress exp2)
        {
            _exp1 = exp1;
            _exp2 = exp2;
        }

        public bool Interpreter(string context)
        {
            return _exp1.Interpreter(context) || _exp2.Interpreter(context);
        }
    }
}